package com.qianniu.napi.admin.entity;

import com.baomidou.mybatisplus.enums.IdType;

import java.math.BigDecimal;
import java.util.Date;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;
import com.fasterxml.jackson.annotation.JsonIgnore;

import java.io.Serializable;

/**
 * <p>
 * 商家配置
 * </p>
 *
 * @author chenxuebin
 * @since 2018-07-17
 */
@TableName("t_merchant_config")
public class MerchantConfig extends Model<MerchantConfig> {

    private static final long serialVersionUID = 1L;

	@TableId(value="id", type= IdType.AUTO)
	private Long id;

	@JsonIgnore
	private Long mid;

	@JsonIgnore
	private Long mpid;

	@JsonIgnore
	private Long uid;

	@JsonIgnore
	private String appid;

    /**
     * 支持分享
     */
	@TableField("is_banner")
	private Integer isBanner;
    /**
     * 支持分享
     */
	@TableField("is_share")
	private Integer isShare;
    /**
     * 支持搜索
     */
	@TableField("is_search")
	private Integer isSearch;

    /**
     * 支持会员
     */
	@TableField("is_miaotui")
	private Integer isMiaotui;

    /**
     * 支持秒退
     */
	@TableField("is_member")
	private Integer isMember;

    /**
     * 支持积分
     */
	@TableField("is_jifen")
	private Integer isJifen;
    /**
     * 支持积分
     */
	@TableField("is_notice")
	private Integer isNotice;
    /**
     * 支持积分
     */
	@TableField("is_home_category")
	private Integer isHomeCategory;
    /**
     * 支持积分
     */
	@TableField("is_home_search")
	private Integer isHomeSearch;

    /**
     * 支持积优惠券
     */
	@TableField("is_coupon")
	private Integer isCoupon;

    /**
     * 是否多门店
     */
	@TableField("is_multishop")
	private Integer isMultishop;

    /**
     * 关于商家模式
     */
	@TableField("about_type")
	private Integer aboutType;

    /**
     * 支持模板消息
     */
	@TableField("is_tmplmsg")
	private Integer isTmplmsg;

    /**
     * 支持模板消息
     */
	@TableField("is_minfo")
	private Integer isMinfo;

	/**
	 * 是否支持会员卡现金业务
	 */
	@TableField("is_ecash_card")
	private Integer isEcashCard;

    /**
     * 支持分类
     */
	@TableField("show_category")
	private Integer showCategory;

    /**
     * 显示销售数量|剩余库存
     */
	@TableField("show_salenum")
	private Integer showSalenum;

    /**
     * banner类型@0：无；1：短banner；2：大banner
     */
	@TableField("banner_type")
	private Integer bannerType;

    /**
     * 多少积分兑换1元
     */
	@TableField("fanjifen_type")
	private Integer fanjifenType;

    /**
     * 多少积分兑换1元
     */
	@TableField("jifen_rate")
	private Integer jifenRate;

	@TableField("is_cache")
	private Integer isCache;

	@TableField("is_nav")
	private Integer isNav;

	@TableField("is_fenxiao")
	private Integer isFenxiao;
	private Integer fslevel;

	@TableField("is_fladmin")
	private Integer isFladmin;
	@TableField("is_hyprice")
	private Integer isHyprice;

	@TableField("is_home_quan")
	private Integer isHomeQuan;

	@TableField("is_xnbi")
	private Integer isXnbi;

	@TableField("is_suofen")
	private Integer isSuofen;

	@TableField("is_duihuan")
	private Integer isDuihuan;

	@TableField(exist = false)
	private boolean cached;

	@TableField(exist = false)
	private String appname;

	/**
	 * 配置版本号
	 */
	private Long version;

	/**
	 * 官网网站地址
	 */
	private String website;

	/**
	 * 关于商家
	 */
	private String aboutus;

    /**
     * 单次消费能够使用最大积分数
     */
	@TableField("max_jifen")
	private Integer maxJifen;

	@TableField(exist = false)
	private Integer jfmount;

	@TableField(exist = false)
	private BigDecimal discount;

	@TableField(exist = false)
	private BigDecimal account;

    /**
     * 分类类型1：竖状分类；2：横状分类
     */
	@TableField("category_type")
	private Integer categoryType;

    /**
     * 分类类型1：竖状分类；2：横状分类
     */
	@TableField("goods_list_type")
	private Integer goodsListType;

    /**
     * 目录层级类别@1：1级(无子品牌)；2：2级（含二级品牌）
     */
	@TableField("category_level_type")
	private Integer categoryLevelType;

    /**
     * 默认会员折扣
     */
	@TableField("member_discount_rate")
	private BigDecimal memberDiscountRate;

	@TableField("selltext_type")
	private Integer selltextType;

    /**
     * 最低提现额度
     */
	@TableField("min_tixian")
	private BigDecimal minTixian;

	/**
	 * 体现方式@ 1：微信提现；2：支付宝提现
	 */
	@TableField("tixian_type")
	private Integer tixianType;

    /**
     * 列表项类型@1：一行1列；2：一行2列；
     */
	@TableField("list_type")
	private Integer listType;

	@TableField(exist = false)
	private Address defaultAddr;

	@JsonIgnore
	private Date createtime;

	@JsonIgnore
	private Date modifytime;

	@JsonIgnore
	private Long modifier;
//
//	@TableField("signfan_type")
//	private Integer signfanType;
//
//	@TableField("signfan_mount")
//	private BigDecimal signfanMount;
//
//	@TableField("readfan_type")
//	private Integer readfanType;
//
//	@TableField("readfan_mount")
//	private BigDecimal readfanMount;
//
//	@TableField("shoujifan_type")
//	private Integer shoujifanType;
//
//	@TableField("shoujifan_mount")
//	private BigDecimal shoujifanMount;

//	@TableField("xffan_type")
//	private Integer xffanType;

//	@TableField("xffan_mount")
//	private BigDecimal xffanMount;

	@TableField("nuserfan_type")
	private Integer nuserfanType;

	@TableField("nuserfan_mount")
	private BigDecimal nuserfanMount;

	@TableField("promotion_cost")
	private BigDecimal promotionCost;

	private Integer pstype;

	@TableField("is_autofan")
	private Integer isAutofan;

	@TableField("fantime_type")
	private Integer fantimeType;

	@TableField("show_forpay")
	private Integer showForpay;

	@TableField("show_commet")
	private Integer showCommet;

	private Integer choumax;
	private Integer confirmhours;
	private Integer autojiedan;


	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Long getMid() {
		return mid;
	}

	public void setMid(Long mid) {
		this.mid = mid;
	}

	public BigDecimal getAccount() {
		return account;
	}

	public void setAccount(BigDecimal account) {
		this.account = account;
	}

	public BigDecimal getDiscount() {
		return discount;
	}

	public void setDiscount(BigDecimal discount) {
		this.discount = discount;
	}

	public Integer getIsHomeCategory() {
		return isHomeCategory;
	}

	public void setIsHomeCategory(Integer isHomeCategory) {
		this.isHomeCategory = isHomeCategory;
	}

	public BigDecimal getMemberDiscountRate() {
		return memberDiscountRate;
	}

	public void setMemberDiscountRate(BigDecimal memberDiscountRate) {
		this.memberDiscountRate = memberDiscountRate;
	}

	public Integer getJfmount() {
		return jfmount;
	}

	public void setJfmount(Integer jfmount) {
		this.jfmount = jfmount;
	}

	public void setJifenRate(Integer jifenRate) {
		this.jifenRate = jifenRate;
	}

	public Integer getMaxJifen() {
		return maxJifen;
	}

	public void setMaxJifen(Integer maxJifen) {
		this.maxJifen = maxJifen;
	}

	public Integer getBannerType() {
		return bannerType;
	}

	public void setBannerType(Integer bannerType) {
		this.bannerType = bannerType;
	}

	public Integer getCategoryType() {
		return categoryType;
	}

	public void setCategoryType(Integer categoryType) {
		this.categoryType = categoryType;
	}

	public Integer getCategoryLevelType() {
		return categoryLevelType;
	}

	public void setCategoryLevelType(Integer categoryLevelType) {
		this.categoryLevelType = categoryLevelType;
	}

	public Integer getListType() {
		return listType;
	}

	public void setListType(Integer listType) {
		this.listType = listType;
	}

	public Integer getIsShare() {
		return isShare;
	}

	public void setIsShare(Integer isShare) {
		this.isShare = isShare;
	}

	public Integer getIsSearch() {
		return isSearch;
	}

	public void setIsSearch(Integer isSearch) {
		this.isSearch = isSearch;
	}

	public Integer getIsMember() {
		return isMember;
	}

	public void setIsMember(Integer isMember) {
		this.isMember = isMember;
	}

	public Integer getIsJifen() {
		return isJifen;
	}

	public void setIsJifen(Integer isJifen) {
		this.isJifen = isJifen;
	}

	public Integer getIsCoupon() {
		return isCoupon;
	}

	public void setIsCoupon(Integer isCoupon) {
		this.isCoupon = isCoupon;
	}

	public Integer getIsMultishop() {
		return isMultishop;
	}

	public void setIsMultishop(Integer isMultishop) {
		this.isMultishop = isMultishop;
	}

	public Integer getIsTmplmsg() {
		return isTmplmsg;
	}

	public void setIsTmplmsg(Integer isTmplmsg) {
		this.isTmplmsg = isTmplmsg;
	}

	public Integer getIsEcashCard() {
		return isEcashCard;
	}

	public void setIsEcashCard(Integer isEcashCard) {
		this.isEcashCard = isEcashCard;
	}

	public Integer getShowCategory() {
		return showCategory;
	}

	public void setShowCategory(Integer showCategory) {
		this.showCategory = showCategory;
	}

	public Integer getJifenRate() {
		return jifenRate;
	}

	public String getAppid() {
		return appid;
	}

	public void setAppid(String appid) {
		this.appid = appid;
	}

	public Integer getIsNotice() {
		return isNotice;
	}

	public void setIsNotice(Integer isNotice) {
		this.isNotice = isNotice;
	}

	public Address getDefaultAddr() {
		return defaultAddr;
	}

	public void setDefaultAddr(Address defaultAddr) {
		this.defaultAddr = defaultAddr;
	}

	public BigDecimal getMinTixian() {
		return minTixian;
	}

	public void setMinTixian(BigDecimal minTixian) {
		this.minTixian = minTixian;
	}

	public Integer getTixianType() {
		return tixianType;
	}

	public void setTixianType(Integer tixianType) {
		this.tixianType = tixianType;
	}

	public Integer getIsCache() {
		return isCache;
	}

	public void setIsCache(Integer isCache) {
		this.isCache = isCache;
	}

	public Integer getGoodsListType() {
		return goodsListType;
	}

	public void setGoodsListType(Integer goodsListType) {
		this.goodsListType = goodsListType;
	}

	public Integer getShowSalenum() {
		return showSalenum;
	}

	public void setShowSalenum(Integer showSalenum) {
		this.showSalenum = showSalenum;
	}

	public Integer getIsNav() {
		return isNav;
	}

	public void setIsNav(Integer isNav) {
		this.isNav = isNav;
	}

	public Integer getAboutType() {
		return aboutType;
	}

	public void setAboutType(Integer aboutType) {
		this.aboutType = aboutType;
	}

	public String getAboutus() {
		return aboutus;
	}

	public void setAboutus(String aboutus) {
		this.aboutus = aboutus;
	}

	public Integer getIsMiaotui() {
		return isMiaotui;
	}

	public void setIsMiaotui(Integer isMiaotui) {
		this.isMiaotui = isMiaotui;
	}

	public Integer getIsMinfo() {
		return isMinfo;
	}

	public void setIsMinfo(Integer isMinfo) {
		this.isMinfo = isMinfo;
	}

	public Long getVersion() {
		return version;
	}

	public void setVersion(Long version) {
		this.version = version;
	}

	public Integer getIsBanner() {
		return isBanner;
	}

	public void setIsBanner(Integer isBanner) {
		this.isBanner = isBanner;
	}

	public Long getUid() {
		return uid;
	}

	public void setUid(Long uid) {
		this.uid = uid;
	}

	public Integer getIsHomeSearch() {
		return isHomeSearch;
	}

	public void setIsHomeSearch(Integer isHomeSearch) {
		this.isHomeSearch = isHomeSearch;
	}

	public Integer getSelltextType() {
		return selltextType;
	}

	public void setSelltextType(Integer selltextType) {
		this.selltextType = selltextType;
	}

	public String getWebsite() {
		return website;
	}

	public void setWebsite(String website) {
		this.website = website;
	}

	public Date getCreatetime() {
		return createtime;
	}

	public void setCreatetime(Date createtime) {
		this.createtime = createtime;
	}

	public Date getModifytime() {
		return modifytime;
	}

	public void setModifytime(Date modifytime) {
		this.modifytime = modifytime;
	}

	public Long getModifier() {
		return modifier;
	}

	public void setModifier(Long modifier) {
		this.modifier = modifier;
	}

	public boolean isCached() {
		return isCache!=null&&isCache==1;
	}

	public Integer getFanjifenType() {
		return fanjifenType;
	}

	public void setFanjifenType(Integer fanjifenType) {
		this.fanjifenType = fanjifenType;
	}

	public Long getMpid() {
		return mpid;
	}

	public void setMpid(Long mpid) {
		this.mpid = mpid;
	}

	public Integer getIsHomeQuan() {
		return isHomeQuan;
	}

	public void setIsHomeQuan(Integer isHomeQuan) {
		this.isHomeQuan = isHomeQuan;
	}

	public Integer getIsFenxiao() {
		return isFenxiao;
	}

	public void setIsFenxiao(Integer isFenxiao) {
		this.isFenxiao = isFenxiao;
	}

	public Integer getIsXnbi() {
		return isXnbi;
	}

	public void setIsXnbi(Integer isXnbi) {
		this.isXnbi = isXnbi;
	}

	public Integer getIsSuofen() {
		return isSuofen;
	}

	public void setIsSuofen(Integer isSuofen) {
		this.isSuofen = isSuofen;
	}

//	public Integer getXffanType() {
//		return xffanType;
//	}
//
//	public void setXffanType(Integer xffanType) {
//		this.xffanType = xffanType;
//	}

//	public BigDecimal getXffanMount() {
//		return xffanMount;
//	}
//
//	public void setXffanMount(BigDecimal xffanMount) {
//		this.xffanMount = xffanMount;
//	}

	public Integer getPstype() {
		return pstype;
	}

	public void setPstype(Integer pstype) {
		this.pstype = pstype;
	}

	public Integer getIsAutofan() {
		return isAutofan;
	}

	public void setIsAutofan(Integer isAutofan) {
		this.isAutofan = isAutofan;
	}

	public Integer getFantimeType() {
		return fantimeType;
	}

	public void setFantimeType(Integer fantimeType) {
		this.fantimeType = fantimeType;
	}

	public Integer getShowForpay() {
		return showForpay;
	}

	public void setShowForpay(Integer showForpay) {
		this.showForpay = showForpay;
	}

	public Integer getIsDuihuan() {
		return isDuihuan;
	}

	public void setIsDuihuan(Integer isDuihuan) {
		this.isDuihuan = isDuihuan;
	}

	public Integer getIsFladmin() {
		return isFladmin;
	}

	public void setIsFladmin(Integer isFladmin) {
		this.isFladmin = isFladmin;
	}

	public Integer getChoumax() {
		return choumax;
	}

	public void setChoumax(Integer choumax) {
		this.choumax = choumax;
	}

//	public Integer getSignfanType() {
//		return signfanType;
//	}
//
//	public void setSignfanType(Integer signfanType) {
//		this.signfanType = signfanType;
//	}
//
//	public BigDecimal getSignfanMount() {
//		return signfanMount;
//	}
//
//	public void setSignfanMount(BigDecimal signfanMount) {
//		this.signfanMount = signfanMount;
//	}
//
//	public Integer getReadfanType() {
//		return readfanType;
//	}
//
//	public void setReadfanType(Integer readfanType) {
//		this.readfanType = readfanType;
//	}
//
//	public BigDecimal getReadfanMount() {
//		return readfanMount;
//	}
//
//	public void setReadfanMount(BigDecimal readfanMount) {
//		this.readfanMount = readfanMount;
//	}
//
//	public Integer getShoujifanType() {
//		return shoujifanType;
//	}
//
//	public void setShoujifanType(Integer shoujifanType) {
//		this.shoujifanType = shoujifanType;
//	}
//
//	public BigDecimal getShoujifanMount() {
//		return shoujifanMount;
//	}
//
//	public void setShoujifanMount(BigDecimal shoujifanMount) {
//		this.shoujifanMount = shoujifanMount;
//	}

	public Integer getNuserfanType() {
		return nuserfanType;
	}

	public void setNuserfanType(Integer nuserfanType) {
		this.nuserfanType = nuserfanType;
	}

	public BigDecimal getNuserfanMount() {
		return nuserfanMount;
	}

	public void setNuserfanMount(BigDecimal nuserfanMount) {
		this.nuserfanMount = nuserfanMount;
	}

	public Integer getFslevel() {
		return fslevel;
	}

	public void setFslevel(Integer fslevel) {
		this.fslevel = fslevel;
	}

	public BigDecimal getPromotionCost() {
		return promotionCost;
	}

	public void setPromotionCost(BigDecimal promotionCost) {
		this.promotionCost = promotionCost;
	}

	public Integer getShowCommet() {
		return showCommet;
	}

	public void setShowCommet(Integer showCommet) {
		this.showCommet = showCommet;
	}

	public Integer getConfirmhours() {
		return confirmhours;
	}

	public void setConfirmhours(Integer confirmhours) {
		this.confirmhours = confirmhours;
	}

	public Integer getAutojiedan() {
		return autojiedan;
	}

	public void setAutojiedan(Integer autojiedan) {
		this.autojiedan = autojiedan;
	}

	public Integer getIsHyprice() {
		return isHyprice;
	}

	public void setIsHyprice(Integer isHyprice) {
		this.isHyprice = isHyprice;
	}

	public String getAppname() {
		return appname;
	}

	public void setAppname(String appname) {
		this.appname = appname;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	@Override
	public String toString() {
		return "MerchantConfig{" +
				"id=" + id +
				", mid=" + mid +
				", mpid=" + mpid +
				", uid=" + uid +
				", appid='" + appid + '\'' +
				", isBanner=" + isBanner +
				", isShare=" + isShare +
				", isSearch=" + isSearch +
				", isMiaotui=" + isMiaotui +
				", isMember=" + isMember +
				", isJifen=" + isJifen +
				", isNotice=" + isNotice +
				", isHomeCategory=" + isHomeCategory +
				", isHomeSearch=" + isHomeSearch +
				", isCoupon=" + isCoupon +
				", isMultishop=" + isMultishop +
				", aboutType=" + aboutType +
				", isTmplmsg=" + isTmplmsg +
				", isMinfo=" + isMinfo +
				", isEcashCard=" + isEcashCard +
				", showCategory=" + showCategory +
				", showSalenum=" + showSalenum +
				", bannerType=" + bannerType +
				", fanjifenType=" + fanjifenType +
				", jifenRate=" + jifenRate +
				", isCache=" + isCache +
				", isNav=" + isNav +
				", isHomeQuan=" + isHomeQuan +
				", cached=" + cached +
				", version=" + version +
				", website='" + website + '\'' +
				", aboutus='" + aboutus + '\'' +
				", maxJifen=" + maxJifen +
				", jfmount=" + jfmount +
				", discount=" + discount +
				", account=" + account +
				", categoryType=" + categoryType +
				", goodsListType=" + goodsListType +
				", categoryLevelType=" + categoryLevelType +
				", memberDiscountRate=" + memberDiscountRate +
				", selltextType=" + selltextType +
				", minTixian=" + minTixian +
				", tixianType=" + tixianType +
				", listType=" + listType +
				", defaultAddr=" + defaultAddr +
				", createtime=" + createtime +
				", modifytime=" + modifytime +
				", modifier=" + modifier +
				'}';
	}
}
